package net.hn.hnms.biz.safety.trinity.link;

import net.hn.hnms.sys.common.core.constant.ServiceNameConstants;
import net.hn.hnms.sys.common.core.domain.R;
import net.hn.hnms.sys.system.api.domain.vo.SysDeptNameForCodeVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @author 智呈物联 nzw
 * @date 2023/1/29
 */
@Component
@FeignClient(contextId = "DeptLinkService", value = ServiceNameConstants.SYSTEM_SERVICE,fallback = DeptLinkServiceFallback.class)
public interface DeptLinkService {

    @GetMapping("/dept/getDeptName")
    R<List<SysDeptNameForCodeVO>> getDeptName();

    @GetMapping("/dept/getParentDeptName/")
    R<SysDeptNameForCodeVO> getParentDeptName(@RequestParam("mineCode")String mineCode);
}
